<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

return new class extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('read_proofs', function (Blueprint $table) {
            $table->id();
            $table->unsignedBigInteger('company_id')->default(0)->index();
            $table->unsignedBigInteger('project_id')->default(0)->index();
            $table->unsignedBigInteger('admin_id')->default(0)->index();
            $table->string('name')->nullable()->comment('施工部位');
            $table->string('brief')->nullable()->comment('大样描述');
            $table->string('rendering')->nullable()->comment('效果图');
            $table->string('number')->nullable()->comment('图纸编号');
            $table->string('node')->nullable()->comment('原图纸节点');
            $table->string('node_drawing')->nullable()->comment('深化节点图纸');
            $table->string('purpose')->nullable()->comment('打样目的');
            $table->date('deepen_date')->nullable()->comment('深化完成时间');
            $table->date('make_date')->nullable()->comment('制作完成时间');
            $table->string('team')->nullable()->comment('制作单位/班组');
            $table->string('images')->nullable()->comment('打样完成照片');
            $table->string('remarks')->nullable()->comment('备注');
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('read_proofs');
    }
};
